Introduction

To better distinguish between the gene regulatory states, we introduce a gene-specific statistic, ‘k-proportion’. This is the percentage of cells with gene expression less than a defined integer value, k, which is determined based on the mean gene expression count. Consider a situation where certain genes exhibit high expression levels in a limited subset of cells. This extreme expression skews the overall average upward, however the k-proportions (a measure reflecting the portion of cells with considerably lower expression) remain high. Essentially, under equivalent mean expressions, regulatory genes display significantly higher values of k-proportions compared to their homeostatic counterparts.

Installation

To install the RegulationIndex package, you can use the code.

devtools::install_github("ChenMengjie/RegulationIndex")

Then load the following libraries used in this tutorial:

library(RegulationIndex)
library(ComplexHeatmap)
## Loading required package: grid
## ========================================
## ComplexHeatmap version 2.10.0
## Bioconductor page: http://bioconductor.org/packages/ComplexHeatmap/
## Github page: https://github.com/jokergoo/ComplexHeatmap
## Documentation: http://jokergoo.github.io/ComplexHeatmap-reference
## 
## If you use it in published research, please cite:
## Gu, Z. Complex heatmaps reveal patterns and correlations in multidimensional 
##   genomic data. Bioinformatics 2016.
## 
## The new InteractiveComplexHeatmap package can directly export static 
## complex heatmaps into an interactive Shiny app with zero effort. Have a try!
## 
## This message can be suppressed by:
##   suppressPackageStartupMessages(library(ComplexHeatmap))
## ========================================
library(viridis)
## Loading required package: viridisLite
library(Seurat)
## Registered S3 method overwritten by 'spatstat.geom':
##   method     from
##   print.boxx cli
## Attaching SeuratObject
library(umap)

Dataset 1: CD34+ cells from one donor

Zheng et al data was downloaded from the 10X website. Only cells that labeled as CD34+ were selected for analysis. There are 277 cells with 31482 genes. We performed UMAP on log-transformed data. Through UMAP visualization, we identified three distinct subgroups within the CD34+ cell population. We used k-means to separate cells into 3 subtypes using their UMAP coordinates. The UMI counts and subtype information have been stored in the RegulationIndex package as dataset CD34.

data(CD34, package="RegulationIndex")
counts <- CD34$counts
final_cluster <- CD34$final_cluster
dimred = umap::umap(counts)$layout
final_colors <- final_cluster
final_colors[final_cluster == 2] <- "#CC8D1A"
final_colors[final_cluster == 3] <- "#8CBEB2"
final_colors[final_cluster == 4] <- "#F06060"

par(mfrow = c(1, 2))
plot(dimred[, 1], dimred[, 2], pch=20, col = final_colors, xlab = "UMAP1", ylab = "UMAP2")

library_size <- apply(counts, 1, sum)
gene_coverage <- apply(counts, 1, function(x){sum(x != 0)})
plot(gene_coverage, library_size, col = final_colors, pch = 20, ylim = c(0, 6000))

The K-proporation inflation test

The main function is Kprop_inflation_test(), which will take in UMI counts and output a list of up-regulated genes that display significantly higher values of k-proportions compared to the majority of genes (homeostatic). Kprop_inflation_test also expects the The grouping IDs of cells through the option grouping. If the grouping is NULL, all cells will be assessed at once. The grouping can be cell types, individuals or any phenotype. If the grouping is supplied, cells will be evaluated by groups. If you have data with complex nested structures, like multiple cell types from multiple donors, you need to run Kprop_inflation_test multiple times. Now only one layer of grouping structure is supported.

There are several options that might need to be adjusted according to the sequencing depth of different experiments. For example, the option cell.depth.ranges inputs a two-value vector of the ranges of total counts per cell. The cells out of the ranges will be removed. The default is c(2500, 60000), set empirically for 10X data. The recommended per cell sequencing depth for 10x Genomics projects is between 30,000 and 70,000 reads. If your sequencing depth is substantially higher or lower than common practice, please adjust min.depth.group and cell.depth.ranges accordingly. This CD34 dataset depth is on the lower end. We set values different from the default to reflect that. The option filter.gene controls whether to reporting IncRNA, mtRNA, or ribosomal RNA in the list of inflated genes. The default is FALSE, i.e., reporting all RNAs.

The function Kprop_inflation_test() will return a list of summary of k-proportion test for each cell group, including: * groupID : the ID of the group. The value is NA if there is no grouping information supplied. * NBdispersion : estimated dispersion parameter * Zscores : a matrix summarizing gene mean, zscore, p-value and q-value for all genes in dat. NAs are reported for genes with mean = 0. * Inflated : a matrix of selected genes that pass qvalue.cutoff and genemean.cutoff.

We applied the k-proportion inflation test on UMI counts for each subtype and with all subtypes combined.

counts <- counts[, !duplicated(colnames(counts))] ## remove duplicated gene names
testdata <- t(counts)
cluster.zscore.summary <- Kprop_inflation_test(testdata, grouping = final_cluster, min.depth.group = 500, cell.depth.ranges = c(500, 10000), genemean.cutoff = 0.5, filter.gene = FALSE)
str(cluster.zscore.summary)
## List of 3
##  $ :List of 4
##   ..$ groupID     : Factor w/ 3 levels "2","3","4": 1
##   ..$ NBdispersion: num 0.317
##   ..$ Zscores     :'data.frame': 31482 obs. of  9 variables:
##   .. ..$ gene_mean   : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ k           : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ kprop_diff  : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ k_proportion: num [1:31482] 1 1 1 1 1 1 1 1 1 1 ...
##   .. ..$ expected_pi : num [1:31482] 1 1 1 1 1 1 1 1 1 1 ...
##   .. ..$ zscore      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ est_var_asym: num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ pvalue      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ qvalue      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   ..$ Inflated    :'data.frame': 33 obs. of  9 variables:
##   .. ..$ gene_mean   : num [1:33] 1.157 0.575 0.787 0.591 1.772 ...
##   .. ..$ k           : num [1:33] 0 0 0 0 0 1 0 0 1 0 ...
##   .. ..$ kprop_diff  : num [1:33] 0.257 0.198 0.214 0.158 0.196 ...
##   .. ..$ k_proportion: num [1:33] 0.63 0.787 0.709 0.74 0.441 ...
##   .. ..$ expected_pi : num [1:33] 0.373 0.59 0.495 0.582 0.245 ...
##   .. ..$ zscore      : num [1:33] 8.5 8.25 7.79 6.52 6.45 ...
##   .. ..$ est_var_asym: num [1:33] 0.116 0.0728 0.0955 0.0748 0.1169 ...
##   .. ..$ pvalue      : num [1:33] 9.74e-18 7.75e-17 3.45e-15 3.58e-11 5.42e-11 ...
##   .. ..$ qvalue      : num [1:33] 2.19e-14 1.63e-13 6.04e-12 8.54e-09 1.27e-08 ...
##  $ :List of 4
##   ..$ groupID     : Factor w/ 3 levels "2","3","4": 2
##   ..$ NBdispersion: num 0.526
##   ..$ Zscores     :'data.frame': 31482 obs. of  9 variables:
##   .. ..$ gene_mean   : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ k           : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ kprop_diff  : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ k_proportion: num [1:31482] 1 1 1 1 1 1 1 1 1 1 ...
##   .. ..$ expected_pi : num [1:31482] 1 1 1 1 1 1 1 1 1 1 ...
##   .. ..$ zscore      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ est_var_asym: num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ pvalue      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ qvalue      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   ..$ Inflated    :'data.frame': 22 obs. of  9 variables:
##   .. ..$ gene_mean   : num [1:22] 1.493 0.707 0.853 1.08 0.92 ...
##   .. ..$ k           : num [1:22] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ kprop_diff  : num [1:22] 0.521 0.398 0.426 0.401 0.368 ...
##   .. ..$ k_proportion: num [1:22] 0.853 0.947 0.92 0.827 0.84 ...
##   .. ..$ expected_pi : num [1:22] 0.332 0.548 0.494 0.425 0.472 ...
##   .. ..$ zscore      : num [1:22] 12.54 11.33 11.32 10.04 9.56 ...
##   .. ..$ est_var_asym: num [1:22] 0.1295 0.0928 0.1061 0.1199 0.111 ...
##   .. ..$ pvalue      : num [1:22] 2.25e-36 4.85e-30 5.22e-30 4.98e-24 5.81e-22 ...
##   .. ..$ qvalue      : num [1:22] 7.09e-32 5.48e-26 5.48e-26 3.92e-20 3.05e-18 ...
##  $ :List of 4
##   ..$ groupID     : Factor w/ 3 levels "2","3","4": 3
##   ..$ NBdispersion: num 0.163
##   ..$ Zscores     :'data.frame': 31482 obs. of  9 variables:
##   .. ..$ gene_mean   : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ k           : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ kprop_diff  : num [1:31482] 0 0 0 0 0 0 0 0 0 0 ...
##   .. ..$ k_proportion: num [1:31482] 1 1 1 1 1 1 1 1 1 1 ...
##   .. ..$ expected_pi : num [1:31482] 1 1 1 1 1 1 1 1 1 1 ...
##   .. ..$ zscore      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ est_var_asym: num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ pvalue      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   .. ..$ qvalue      : num [1:31482] NA NA NA NA NA NA NA NA NA NA ...
##   ..$ Inflated    :'data.frame': 15 obs. of  9 variables:
##   .. ..$ gene_mean   : num [1:15] 1.667 1.576 2.091 0.606 0.727 ...
##   .. ..$ k           : num [1:15] 0 0 1 0 0 1 0 0 1 3 ...
##   .. ..$ kprop_diff  : num [1:15] 0.559 0.542 0.274 0.227 0.224 ...
##   .. ..$ k_proportion: num [1:15] 0.788 0.788 0.697 0.788 0.727 ...
##   .. ..$ expected_pi : num [1:15] 0.229 0.246 0.423 0.561 0.503 ...
##   .. ..$ zscore      : num [1:15] 9.78 9.4 4.88 4.83 4.41 ...
##   .. ..$ est_var_asym: num [1:15] 0.1078 0.1096 0.1038 0.0727 0.0855 ...
##   .. ..$ pvalue      : num [1:15] 7.05e-23 2.69e-21 5.35e-07 6.69e-07 5.26e-06 ...
##   .. ..$ qvalue      : num [1:15] 2.22e-18 4.23e-17 3.75e-04 4.58e-04 3.18e-03 ...

If the grouping is not provided, the inflation will be evaluated treating all cells as a single group.

cluster.zscore.summary2 <- Kprop_inflation_test(testdata, grouping = NULL, min.depth.group = 500, cell.depth.ranges = c(500, 10000), genemean.cutoff = 0.5, filter.gene = FALSE)

Wave plots

We generated wave plots for each subgroup separately and for all subgroups combined. Consequently, we observed that the empirical distribution of k-proportions in homeostatic genes (most genes) closely aligns with those from negative binomial distributions with the same dispersion level. In relatively homogeneous cell populations, the resulting distribution approximates those from a Poisson distribution. In subgroup 3, the dispersion level is 0.163, indicating similarity to a Poisson. However, as cellular heterogeneity increases, so does the dispersion level. In subgroup 2, the dispersion level is 0.526, indicating increased variability in gene expression. When considering all subgroups together, the dispersion level is 1.4.

cluster.zscore.summary[[1]]$NBdispersion
## [1] 0.3171141
cluster.zscore.summary[[2]]$NBdispersion
## [1] 0.5259099
cluster.zscore.summary[[3]]$NBdispersion
## [1] 0.163134
cluster.zscore.summary2$NBdispersion
## [1] 1.38826

In all these scenarios, we consistently observe ‘droplets,’ which signify genes undergoing active regulation.

wave_one <- waveplot(cluster.zscore.summary[[1]], show_mean_cutoff = 0.5, xmax = 10, add_poisson_line = TRUE)
## Loading required package: ggplot2
wave_one
## Warning: Removed 15 rows containing missing values (geom_point).

wave_two <- waveplot(cluster.zscore.summary[[2]], show_mean_cutoff = 0.5, xmax = 10, add_poisson_line = TRUE)
wave_two
## Warning: Removed 73 rows containing missing values (geom_point).

wave_three <- waveplot(cluster.zscore.summary[[3]], show_mean_cutoff = 0.5, xmax = 10, add_poisson_line = TRUE)
wave_three
## Warning: Removed 33 rows containing missing values (geom_point).

wave_all <- waveplot(cluster.zscore.summary2, show_mean_cutoff = 0.5, xmax = 10, add_poisson_line = TRUE)
wave_all
## Warning: Removed 17 rows containing missing values (geom_point).

If you only want to show messenger RNAs, you can set filter.gene = TRUE.

cluster.zscore.summary <- Kprop_inflation_test(testdata, grouping = final_cluster, min.depth.group = 500, cell.depth.ranges = c(500, 10000), genemean.cutoff = 0.5, filter.gene = TRUE)
wave_one <- waveplot(cluster.zscore.summary[[1]], separate.RNA = FALSE, show_mean_cutoff = 0.5, xmax = 10, add_poisson_line = TRUE)
wave_one
## Warning: Removed 15 rows containing missing values (geom_point).

Heatmap of inflated genes

Next we can make heatmap to visualize the UMI counts of inflated genes.

genes <- rownames(cluster.zscore.summary2$Inflated)
genes <- c(genes, rownames(cluster.zscore.summary[[3]]$Inflated), rownames(cluster.zscore.summary[[2]]$Inflated), rownames(cluster.zscore.summary[[1]]$Inflated))

groups <- c(rep("5", nrow(cluster.zscore.summary2$Inflated)),
            rep("4", nrow(cluster.zscore.summary[[3]]$Inflated)),
            rep("3", nrow(cluster.zscore.summary[[2]]$Inflated)),
            rep("2", nrow(cluster.zscore.summary[[1]]$Inflated)))

subcounts <- t(counts[, genes])
subcounts[subcounts>20] <- 20

Colors <- viridis(40)
cell_type <- final_cluster

ha = HeatmapAnnotation(
  cell_type = cell_type,
  border = TRUE)

Heatmap(subcounts, name = "CD34+ inflated genes", cluster_row_slices = FALSE, cluster_column_slices = FALSE,
        column_split = factor(cell_type), row_split = factor(groups),
        top_annotation = ha,
        column_title_gp = gpar(fill = c( "#CC8D1A", "#8CBEB2", "#F06060")),
        col=Colors, row_title_gp = gpar(fill = c( "#CC8D1A", "#8CBEB2", "#F06060", "#5C4B51")))

We can visualize log-normalized data too.

subcounts <- t(counts[, genes])
test.normal <- NormalizeData(subcounts)

Heatmap(as.matrix(test.normal), name = "CD34+ inflated genes", cluster_row_slices = FALSE, cluster_column_slices = FALSE,
        column_split = factor(cell_type), row_split = factor(groups),
        top_annotation = ha,
        column_title_gp = gpar(fill = c( "#CC8D1A", "#8CBEB2", "#F06060")),
        col=Colors, row_title_gp = gpar(fill = c( "#CC8D1A", "#8CBEB2", "#F06060", "#5C4B51")))

Session information

Here is the session information.

devtools::session_info()
## ─ Session info ───────────────────────────────────────────────────────────────
##  setting  value
##  version  R version 4.1.2 (2021-11-01)
##  os       macOS Big Sur 10.16
##  system   x86_64, darwin17.0
##  ui       X11
##  language (EN)
##  collate  en_US.UTF-8
##  ctype    en_US.UTF-8
##  tz       America/Chicago
##  date     2024-01-02
##  pandoc   2.19.2 @ /Applications/RStudio.app/Contents/Resources/app/quarto/bin/tools/ (via rmarkdown)
## 
## ─ Packages ───────────────────────────────────────────────────────────────────
##  package         * version date (UTC) lib source
##  abind             1.4-5   2016-07-21 [1] CRAN (R 4.1.0)
##  askpass           1.1     2019-01-13 [1] CRAN (R 4.1.0)
##  assertthat        0.2.1   2019-03-21 [1] CRAN (R 4.1.0)
##  BiocGenerics      0.40.0  2021-10-26 [1] Bioconductor
##  brio              1.1.3   2021-11-30 [1] CRAN (R 4.1.0)
##  bslib             0.3.1   2021-10-06 [1] CRAN (R 4.1.0)
##  cachem            1.0.6   2021-08-19 [1] CRAN (R 4.1.0)
##  callr             3.7.0   2021-04-20 [1] CRAN (R 4.1.0)
##  circlize          0.4.14  2022-02-11 [1] CRAN (R 4.1.2)
##  cli               3.1.1   2022-01-20 [1] CRAN (R 4.1.2)
##  clue              0.3-65  2023-09-23 [1] CRAN (R 4.1.2)
##  cluster           2.1.2   2021-04-17 [1] CRAN (R 4.1.2)
##  codetools         0.2-18  2020-11-04 [1] CRAN (R 4.1.2)
##  colorspace        2.0-2   2021-06-24 [1] CRAN (R 4.1.0)
##  ComplexHeatmap  * 2.10.0  2021-10-26 [1] Bioconductor
##  cowplot           1.1.1   2020-12-30 [1] CRAN (R 4.1.0)
##  crayon            1.4.2   2021-10-29 [1] CRAN (R 4.1.0)
##  data.table        1.14.2  2021-09-27 [1] CRAN (R 4.1.0)
##  DBI               1.1.2   2021-12-20 [1] CRAN (R 4.1.0)
##  deldir            1.0-6   2021-10-23 [1] CRAN (R 4.1.0)
##  desc              1.4.0   2021-09-28 [1] CRAN (R 4.1.0)
##  devtools          2.4.3   2021-11-30 [1] CRAN (R 4.1.0)
##  digest            0.6.29  2021-12-01 [1] CRAN (R 4.1.0)
##  doParallel        1.0.17  2022-02-07 [1] CRAN (R 4.1.2)
##  dplyr             1.0.7   2021-06-18 [1] CRAN (R 4.1.0)
##  ellipsis          0.3.2   2021-04-29 [1] CRAN (R 4.1.0)
##  evaluate          0.14    2019-05-28 [1] CRAN (R 4.1.0)
##  fansi             1.0.2   2022-01-14 [1] CRAN (R 4.1.2)
##  farver            2.1.0   2021-02-28 [1] CRAN (R 4.1.0)
##  fastmap           1.1.0   2021-01-25 [1] CRAN (R 4.1.0)
##  fitdistrplus      1.1-6   2021-09-28 [1] CRAN (R 4.1.0)
##  foreach           1.5.2   2022-02-02 [1] CRAN (R 4.1.2)
##  fs                1.5.2   2021-12-08 [1] CRAN (R 4.1.0)
##  future            1.23.0  2021-10-31 [1] CRAN (R 4.1.0)
##  future.apply      1.8.1   2021-08-10 [1] CRAN (R 4.1.0)
##  generics          0.1.2   2022-01-31 [1] CRAN (R 4.1.2)
##  GetoptLong        1.0.5   2020-12-15 [1] CRAN (R 4.1.0)
##  ggplot2         * 3.3.5   2021-06-25 [1] CRAN (R 4.1.0)
##  ggrepel           0.9.1   2021-01-15 [1] CRAN (R 4.1.0)
##  ggridges          0.5.3   2021-01-08 [1] CRAN (R 4.1.0)
##  GlobalOptions     0.1.2   2020-06-10 [1] CRAN (R 4.1.0)
##  globals           0.14.0  2020-11-22 [1] CRAN (R 4.1.0)
##  glue              1.6.1   2022-01-22 [1] CRAN (R 4.1.2)
##  goftest           1.2-3   2021-10-07 [1] CRAN (R 4.1.0)
##  gridExtra         2.3     2017-09-09 [1] CRAN (R 4.1.0)
##  gtable            0.3.0   2019-03-25 [1] CRAN (R 4.1.0)
##  highr             0.9     2021-04-16 [1] CRAN (R 4.1.0)
##  htmltools         0.5.2   2021-08-25 [1] CRAN (R 4.1.0)
##  htmlwidgets       1.5.4   2021-09-08 [1] CRAN (R 4.1.0)
##  httpuv            1.6.5   2022-01-05 [1] CRAN (R 4.1.2)
##  httr              1.4.2   2020-07-20 [1] CRAN (R 4.1.0)
##  ica               1.0-2   2018-05-24 [1] CRAN (R 4.1.0)
##  igraph            1.2.11  2022-01-04 [1] CRAN (R 4.1.2)
##  IRanges           2.28.0  2021-10-26 [1] Bioconductor
##  irlba             2.3.5   2021-12-06 [1] CRAN (R 4.1.0)
##  iterators         1.0.13  2020-10-15 [1] CRAN (R 4.1.0)
##  jquerylib         0.1.4   2021-04-26 [1] CRAN (R 4.1.0)
##  jsonlite          1.7.3   2022-01-17 [1] CRAN (R 4.1.2)
##  KernSmooth        2.23-20 2021-05-03 [1] CRAN (R 4.1.2)
##  knitr             1.37    2021-12-16 [1] CRAN (R 4.1.0)
##  labeling          0.4.2   2020-10-20 [1] CRAN (R 4.1.0)
##  later             1.3.0   2021-08-18 [1] CRAN (R 4.1.0)
##  lattice           0.20-45 2021-09-22 [1] CRAN (R 4.1.2)
##  lazyeval          0.2.2   2019-03-15 [1] CRAN (R 4.1.0)
##  leiden            0.3.9   2021-07-27 [1] CRAN (R 4.1.0)
##  lifecycle         1.0.1   2021-09-24 [1] CRAN (R 4.1.0)
##  listenv           0.8.0   2019-12-05 [1] CRAN (R 4.1.0)
##  lmtest            0.9-39  2021-11-07 [1] CRAN (R 4.1.0)
##  magrittr          2.0.2   2022-01-26 [1] CRAN (R 4.1.2)
##  MASS              7.3-54  2021-05-03 [1] CRAN (R 4.1.2)
##  Matrix            1.3-4   2021-06-01 [1] CRAN (R 4.1.2)
##  matrixStats       0.61.0  2021-09-17 [1] CRAN (R 4.1.0)
##  memoise           2.0.1   2021-11-26 [1] CRAN (R 4.1.0)
##  mgcv              1.8-38  2021-10-06 [1] CRAN (R 4.1.2)
##  mime              0.12    2021-09-28 [1] CRAN (R 4.1.0)
##  miniUI            0.1.1.1 2018-05-18 [1] CRAN (R 4.1.0)
##  munsell           0.5.0   2018-06-12 [1] CRAN (R 4.1.0)
##  nlme              3.1-153 2021-09-07 [1] CRAN (R 4.1.2)
##  openssl           1.4.6   2021-12-19 [1] CRAN (R 4.1.0)
##  parallelly        1.30.0  2021-12-17 [1] CRAN (R 4.1.0)
##  patchwork         1.1.1   2020-12-17 [1] CRAN (R 4.1.0)
##  pbapply           1.5-0   2021-09-16 [1] CRAN (R 4.1.0)
##  pillar            1.7.0   2022-02-01 [1] CRAN (R 4.1.2)
##  pkgbuild          1.3.1   2021-12-20 [1] CRAN (R 4.1.0)
##  pkgconfig         2.0.3   2019-09-22 [1] CRAN (R 4.1.0)
##  pkgload           1.2.4   2021-11-30 [1] CRAN (R 4.1.0)
##  plotly            4.10.0  2021-10-09 [1] CRAN (R 4.1.0)
##  plyr              1.8.6   2020-03-03 [1] CRAN (R 4.1.0)
##  png               0.1-7   2013-12-03 [1] CRAN (R 4.1.0)
##  polyclip          1.10-0  2019-03-14 [1] CRAN (R 4.1.0)
##  prettyunits       1.1.1   2020-01-24 [1] CRAN (R 4.1.0)
##  processx          3.5.2   2021-04-30 [1] CRAN (R 4.1.0)
##  promises          1.2.0.1 2021-02-11 [1] CRAN (R 4.1.0)
##  ps                1.6.0   2021-02-28 [1] CRAN (R 4.1.0)
##  purrr             0.3.4   2020-04-17 [1] CRAN (R 4.1.0)
##  R6                2.5.1   2021-08-19 [1] CRAN (R 4.1.0)
##  RANN              2.6.1   2019-01-08 [1] CRAN (R 4.1.0)
##  RColorBrewer      1.1-2   2014-12-07 [1] CRAN (R 4.1.0)
##  Rcpp              1.0.8   2022-01-13 [1] CRAN (R 4.1.2)
##  RcppAnnoy         0.0.19  2021-07-30 [1] CRAN (R 4.1.0)
##  RegulationIndex * 0.1.0   2023-12-31 [1] Github (ChenMengjie/RegulationIndex@6c967e0)
##  remotes           2.4.2   2021-11-30 [1] CRAN (R 4.1.0)
##  reshape2          1.4.4   2020-04-09 [1] CRAN (R 4.1.0)
##  reticulate        1.24    2022-01-26 [1] CRAN (R 4.1.2)
##  rjson             0.2.21  2022-01-09 [1] CRAN (R 4.1.2)
##  rlang             1.0.0   2022-01-26 [1] CRAN (R 4.1.2)
##  rmarkdown         2.11    2021-09-14 [1] CRAN (R 4.1.2)
##  ROCR              1.0-11  2020-05-02 [1] CRAN (R 4.1.0)
##  rpart             4.1-15  2019-04-12 [1] CRAN (R 4.1.2)
##  rprojroot         2.0.2   2020-11-15 [1] CRAN (R 4.1.0)
##  RSpectra          0.16-0  2019-12-01 [1] CRAN (R 4.1.0)
##  rstudioapi        0.13    2020-11-12 [1] CRAN (R 4.1.0)
##  Rtsne             0.15    2018-11-10 [1] CRAN (R 4.1.0)
##  S4Vectors         0.32.3  2021-11-21 [1] Bioconductor
##  sass              0.4.0   2021-05-12 [1] CRAN (R 4.1.0)
##  scales            1.1.1   2020-05-11 [1] CRAN (R 4.1.0)
##  scattermore       0.8     2022-02-14 [1] CRAN (R 4.1.2)
##  sctransform       0.3.3   2022-01-13 [1] CRAN (R 4.1.2)
##  sessioninfo       1.2.2   2021-12-06 [1] CRAN (R 4.1.0)
##  Seurat          * 4.1.0   2022-01-14 [1] CRAN (R 4.1.2)
##  SeuratObject    * 4.0.4   2021-11-23 [1] CRAN (R 4.1.0)
##  shape             1.4.6   2021-05-19 [1] CRAN (R 4.1.0)
##  shiny             1.7.1   2021-10-02 [1] CRAN (R 4.1.0)
##  spatstat.core     2.3-2   2021-11-26 [1] CRAN (R 4.1.0)
##  spatstat.data     2.1-2   2021-12-17 [1] CRAN (R 4.1.0)
##  spatstat.geom     2.3-2   2022-02-12 [1] CRAN (R 4.1.2)
##  spatstat.sparse   2.1-0   2021-12-17 [1] CRAN (R 4.1.0)
##  spatstat.utils    2.3-0   2021-12-12 [1] CRAN (R 4.1.0)
##  stringi           1.7.6   2021-11-29 [1] CRAN (R 4.1.0)
##  stringr           1.4.0   2019-02-10 [1] CRAN (R 4.1.0)
##  survival          3.2-13  2021-08-24 [1] CRAN (R 4.1.2)
##  tensor            1.5     2012-05-05 [1] CRAN (R 4.1.0)
##  testthat          3.1.2   2022-01-20 [1] CRAN (R 4.1.2)
##  tibble            3.1.6   2021-11-07 [1] CRAN (R 4.1.0)
##  tidyr             1.2.0   2022-02-01 [1] CRAN (R 4.1.2)
##  tidyselect        1.1.1   2021-04-30 [1] CRAN (R 4.1.0)
##  umap            * 0.2.7.0 2020-11-04 [1] CRAN (R 4.1.0)
##  usethis           2.1.5   2021-12-09 [1] CRAN (R 4.1.0)
##  utf8              1.2.2   2021-07-24 [1] CRAN (R 4.1.0)
##  uwot              0.1.11  2021-12-02 [1] CRAN (R 4.1.0)
##  vctrs             0.3.8   2021-04-29 [1] CRAN (R 4.1.0)
##  viridis         * 0.6.2   2021-10-13 [1] CRAN (R 4.1.0)
##  viridisLite     * 0.4.0   2021-04-13 [1] CRAN (R 4.1.0)
##  withr             2.4.3   2021-11-30 [1] CRAN (R 4.1.0)
##  xfun              0.29    2021-12-14 [1] CRAN (R 4.1.0)
##  xtable            1.8-4   2019-04-21 [1] CRAN (R 4.1.0)
##  yaml              2.2.2   2022-01-25 [1] CRAN (R 4.1.2)
##  zoo               1.8-9   2021-03-09 [1] CRAN (R 4.1.0)
## 
##  [1] /Library/Frameworks/R.framework/Versions/4.1/Resources/library
## 
## ──────────────────────────────────────────────────────────────────────────────